package com.lh.project.common;

import com.lh.project.model.vo.UserVO;

public class UserHolder {
    private static final ThreadLocal<UserVO> tl = new ThreadLocal<>();
    //设置用户信息
    public static void saveUserVO(UserVO user){tl.set(user);}
    //获取用户信息
    public static UserVO getUser(){return tl.get();}
    //移除用户信息
    public static void removeUser(){tl.remove();}
}
